package cn.micai.base.string;

/**
 * 描述：
 * <p>
 *
 * @author: 赵新国
 * @date: 2018/6/11 10:55
 */
public class StringConcatenateExample {

    public static void main(String [] args) {

        String str1 = "hello";
        String str2 = "java2blog";
        String resultUsingPlus = str1 + str2;
        System.out.println(resultUsingPlus);

        String concat = str1.concat(str2);
        System.out.println(concat);

        String string = new StringBuffer(str1).append(str2).toString();
        System.out.println(string);

    }
}
